package org.jeecg.modules.phone.service.impl;

import org.apache.shiro.SecurityUtils;
import org.checkerframework.checker.units.qual.A;
import org.jeecg.common.system.api.ISysBaseAPI;
import org.jeecg.common.system.vo.LoginUser;
import org.jeecg.common.util.SpringContextUtils;
import org.jeecg.modules.phone.entity.PhoneAccountTask;
import org.jeecg.modules.phone.mapper.PhoneAccountTaskMapper;
import org.jeecg.modules.phone.service.IPhoneAccountTaskService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import java.util.List;

/**
 * @Description: 账号的任务
 * @Author: jeecg-boot
 * @Date:   2022-08-11
 * @Version: V1.0
 */
@Service
public class PhoneAccountTaskServiceImpl extends ServiceImpl<PhoneAccountTaskMapper, PhoneAccountTask> implements IPhoneAccountTaskService {

    @Autowired
    PhoneAccountTaskMapper phoneAccountTaskMapper;

    @Value("${server.name}")
    private String  serverName;

    @Override
    public Boolean checkHasTask( ) {
      LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
//        ISysBaseAPI sysBaseApi = SpringContextUtils.getBean(ISysBaseAPI.class);
//        List<String> departIdsByUsername = sysBaseApi.getDepartIdsByUsername(sysUser.getUsername());
//        if(departIdsByUsername.size()>0){
//
//        }else{
//
//        }

        return null;
    }
}
